<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags" %>
<%@taglib prefix="sj" uri="/struts-jquery-tags"%>
<%@page import="com.lemurian.bankdata.lite.utils.GlobalFunction" %>

<div class="header"><span><span class="ico gray administrator"></span>Add User</span>
</div><!-- End header -->	
<div class="content" >
	<s:form name="formBody" id="validation_demo">
	    <s:hidden name="start"/>
	    <s:hidden name="count"/>
	    <s:hidden name="orderBy"/>
	    <s:hidden name="ascDesc"/>
	    <s:hidden name="previousPage"/>
	    <s:hidden name="actionMethod" value="%{actionMethod}"/>
	    <s:hidden name="subaction"/>
	    <s:hidden name="id" value="%{@com.lemurian.bankdata.lite.utils.GlobalFunction@encodeParameter(id)}"/>
	    <s:token/>
	
		<!-- Third / Half column-->
		<div class="widgets">
		
		<div class="twoOne">
			<div class="section ">
				<label><s:text name="label.loginId"/><small>Login Id yang akan digunakan</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required] text-input large" name="user.loginId"
								labelposition="left" maxlength="30" id="loginId" readonly="%{readOnly}" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.name"/><small>Nama dari user</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required] text-input large" name="user.name"
								labelposition="left" maxlength="30" id="name" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.email"/><small>Email dari user</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required,custom[email]] text-input large" name="user.email"
								labelposition="left" maxlength="30" id="email" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.birthDate"/><small>Tanggal lahir user</small></label>   
				<div> 
					<s:textfield type="text" id="birthhday" cssClass="text-input birthday large " name="birthDate"
								readonly="readonly" labelposition="left" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.address1"/><small>Alamat dari user</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required] text-input large" name="user.address1"
								labelposition="left" maxlength="30" id="address1" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.address2"/><!--<small>Type atau Deskripsi Aktivitas</small>--></label>   
				<div> 
				    <s:textfield cssClass="large" name="user.address2"
								labelposition="left" maxlength="30" id="address2" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.city"/><small>Kota dimana user tinggal</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required] text-input large" name="user.city"
								labelposition="left" maxlength="30" id="city" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.zipCode"/><small>Kode Pos dimana user tinggal</small></label>   
				<div> 
				    <s:textfield cssClass="large" name="user.zipCode"
								labelposition="left" maxlength="6" id="zipCode" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.mobilePhone"/><small>No Hp dari user</small></label>   
				<div> 
				    <s:textfield cssClass="validate[required] text-input large" name="user.mobilePhone"
								labelposition="left" maxlength="15" id="mobilePhone" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.phone1"/><small>Telephone Kantor dari user</small></label>   
				<div> 
				    <s:textfield cssClass="large" name="user.phone1"
								labelposition="left" maxlength="15" id="phone1" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.phone2"/><small>Telephone Rumah dari user</small></label>   
				<div> 
				    <s:textfield cssClass="large" name="user.phone2"
								labelposition="left" maxlength="15" id="phone2" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.fax"/><small>No Fax dari user</small></label>   
				<div> 
				    <s:textfield cssClass="large" name="user.fax"
								labelposition="left" maxlength="15" id="fax" autocomplete="off"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.department"/><small>Departement atau divisi dari user</small></label>   
				<div> 
					<s:select cssClass="validate[required] large chzn-select" list="departments" listKey="%{@com.lemurian.bankdata.lite.utils.GlobalFunction@encodeParameter(id)}" listValue="name" name="departmentId" headerKey="0" headerValue="Select below" tooltip="" value="%{@com.lemurian.bankdata.lite.utils.GlobalFunction@encodeParameter(departmentId)}"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.userType"/><small>Type untuk pengelompokan user</small></label>   
				<div> 
					<s:select cssClass="validate[required] large chzn-select" list="userTypes" listKey="%{@com.lemurian.bankdata.lite.utils.GlobalFunction@encodeParameter(id)}" listValue="name" name="userTypeId" headerKey="0" headerValue="Select below" tooltip="" value="%{@com.lemurian.bankdata.lite.utils.GlobalFunction@encodeParameter(userTypeId)}"/>
				</div>
			</div>
			
			<div class="section ">
				<label><s:text name="label.groups"/><small>Navigasi yang akan digunakan user</small></label>   
				<div style="width: 74%!importand"> 
					<s:select list="userGroups" name="groupIdList" listKey="id" listValue="groupName" multiple="true" size="10" cssClass="large"/>
				</div>
			</div>

			<div class="section last">
	            <div>
	            	<s:submit action="%{actionMethod}" value="Simpan" cssClass="uibutton" cssStyle="width:125px"/>
	            	<a href="UserAction_list.do" class="uibutton special" style="width:125px;">Kembali</a>
	           	</div>
	        </div>
		</div>
		
		</div><!-- End Third / Half column-->
	
	</s:form>

   <!-- clear fix -->
<div class="clear"></div>

</div><!-- End content -->